-
Notifications
You must be signed in to change notification settings - Fork 6
/
PieceImages.java
45 lines (40 loc) · 1.57 KB
/
PieceImages.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package com.chessgame.Pieces;
import java.awt.Color;
import java.nio.file.Path;
import javax.swing.ImageIcon;
public class PieceImages {
static Color WHITECOLOR = Color.WHITE;
static Color BLACKCOLOR = Color.BLACK;
static String PAWN = "♟";
static String ROOK = "♜";
static String KNIGHT = "♞";
static String BISHOP = "♝";
static String QUEEN = "♛";
static String KING = "♚";
static ImageIcon wk;
static ImageIcon bk;
static ImageIcon wr;
static ImageIcon br;
static ImageIcon wq;
static ImageIcon bq;
static ImageIcon wb;
static ImageIcon bb;
static ImageIcon wn;
static ImageIcon bn;
static ImageIcon wp;
static ImageIcon bp;
public PieceImages() {
wk = new ImageIcon(getClass().getResource("../Resources/images/wk.png"));
bk = new ImageIcon(getClass().getResource("../Resources/images/bk.png"));
wr = new ImageIcon(getClass().getResource("../Resources/images/wr.png"));
br = new ImageIcon(getClass().getResource("../Resources/images/br.png"));
wq = new ImageIcon(getClass().getResource("../Resources/images/wq.png"));
bq = new ImageIcon(getClass().getResource("../Resources/images/bq.png"));
wb = new ImageIcon(getClass().getResource("../Resources/images/wb.png"));
bb = new ImageIcon(getClass().getResource("../Resources/images/bb.png"));
wn = new ImageIcon(getClass().getResource("../Resources/images/wn.png"));
bn = new ImageIcon(getClass().getResource("../Resources/images/bn.png"));
wp = new ImageIcon(getClass().getResource("../Resources/images/wp.png"));
bp = new ImageIcon(getClass().getResource("../Resources/images/bp.png"));
}
}